<template>
	<div id="timeTable">
		<el-collapse>
			<el-collapse-item title="已完成节点" name="1">
				<el-table :data="completed" style="width: 100%">
					<el-table-column type="index"></el-table-column>
					<el-table-column prop="NDFromT" label="执行环节"></el-table-column>
					<el-table-column prop="name" label="办理情况"></el-table-column>
					<el-table-column prop="ActionTypeText" label="状态"></el-table-column>
					<el-table-column prop="EmpFromT" label="执行人"></el-table-column>
					<el-table-column prop="RDT" label="开始时间"></el-table-column>
					<el-table-column prop="address" label="结束时间"></el-table-column>
				</el-table>
			</el-collapse-item>
			<el-collapse-item title="未完成节点" name="2">
				<el-table :data="unfinished" style="width: 100%">
					<el-table-column type="index"></el-table-column>
					<el-table-column prop="FK_NodeText" label="执行环节"></el-table-column>
					<el-table-column prop="IsRead" label="办理情况"></el-table-column>
					<el-table-column prop="IsRead" label="状态"></el-table-column>
					<el-table-column prop="FK_Emp" label="执行人"></el-table-column>
					<el-table-column prop="RDT" label="开始时间"></el-table-column>
					<el-table-column prop="address" label="结束时间"></el-table-column>
				</el-table>
			</el-collapse-item>
		</el-collapse>
	</div>
</template>

<script>
export default {
	name: "timeTable",

	data() {
		return {
            data:[],
			completed: [],
			unfinished: [],
			activeNames: ["1"]
		};
	},

	beforeCreate() {},

	created() {},
	mounted() {
		this.$Bus.$on("track", () => {
			console.log("进入时间轴");
			this.data = this.$store.getters.getTrack;
			this.completed = this.data.Track.sort((a,b)=>{ return a.NDFrom-b.NDFrom});//已完成
			console.log('===',this.completed);
			this.data.WF_GenerWorkerList.forEach(item=>{
				if(item.IsPass !=1){
					this.unfinished.push(item)
				}
			})  //未完成
			// this.drawing();
		});
	},

	methods: {},

	//监听
	computed: {},

	components: {},

	//监听后执行动作
	watch: {}
};
</script>

<style lang="less" scoped>
/deep/ .el-card__body {
	p {
		line-height: 1;
	}
}
.portrait {
	width: 50px;
	height: 50px;
	border-radius: 50%;
}
</style>